package com.wgts.wgts.dagger.module;

import com.wgts.wgts.dagger.scope.ActivityScope;
import com.wgts.wgts.mvp.model.IMyExtensionActivityModel;
import com.wgts.wgts.mvp.model.imp.MyExtensionActivityModel;
import com.wgts.wgts.mvp.presenter.IMyExtensionActivityPresenter;
import com.wgts.wgts.mvp.presenter.imp.MyExtensionActivityPresenter;
import com.wgts.wgts.mvp.view.IMyExtensionActivityView;
import com.wgts.wgts.netmodle.NetService;

import dagger.Module;
import dagger.Provides;

@Module
public class MyExtensionActivityModule {

    private IMyExtensionActivityView view;

    public MyExtensionActivityModule(IMyExtensionActivityView view) {
        this.view = view;
    }

    @ActivityScope
    @Provides

    public IMyExtensionActivityView provideView(){
        return view;
    }

    @ActivityScope
    @Provides
    public IMyExtensionActivityModel provideModel(NetService netService){
        return new MyExtensionActivityModel(netService);
    }

    @ActivityScope
    @Provides
    public IMyExtensionActivityPresenter providePresenter(IMyExtensionActivityView view, IMyExtensionActivityModel model){
        return new MyExtensionActivityPresenter(view, model);
    }


}
